/**
 *  任务消息传输vo
 */
package com.smarthome.domain.vo.boss;

/**
 * @author dhc
 * @date 2016年3月29日 下午10:10:32
 * @title 任务消息传输vo
 */
public class TaskMessageVo {

	/** 消息类型 */
	private TaskMessageType messageType;

	/** 查询参数 */
	private String param;
	/** 消息提醒条数 **/
	private Long count;

	private String descript;

	private String content;

	/** 请求的url */
	private String url;
	/** 类型 */
	private Long type;
	/** 类型名 */
	private String typeName;
	
	private String code;

	public TaskMessageType getMessageType() {
		if(null != messageType){
			this.url = messageType.url;
			this.type = messageType.type;
			this.typeName = messageType.typeName;
			this.code = messageType.getCode();
		}
		return messageType;
	}

	public void setMessageType(TaskMessageType messageType) {
		this.messageType = messageType;
	}

	public String getParam() {
		return param;
	}

	public void setParam(String param) {
		this.param = param;
	}

	public Long getCount() {
		return count;
	}

	public void setCount(Long count) {
		this.count = count;
	}

	public String getDescript() {
		return descript;
	}

	public void setDescript(String descript) {
		this.descript = descript;
	}

	public String getContent() {
		return content;
	}

	public void setContent(String content) {
		this.content = content;
	}

	public String getUrl() {
		return url;
	}

	public void setUrl(String url) {
		this.url = url;
	}

	public Long getType() {
		return type;
	}

	public void setType(Long type) {
		this.type = type;
	}

	public String getTypeName() {
		return typeName;
	}

	public void setTypeName(String typeName) {
		this.typeName = typeName;
	}

	public String getCode() {
		return code;
	}
	
	public void setCode(String code) {
		this.code = code;
	}
	/**
	 * 
	 * @author dhc
	 * @date 2016年3月29日 下午10:29:57
	 * @title 消息类型
	 */
	public enum TaskMessageType {
		USERREVIEW(1l,"owner_check", "审核业主", "/accountDoor/views"),
		SENDCOURIER(2l,"send_courier","快递代发","/views/kuaidiXiyi/sendCourier.jsp"),
		PROPERTYSERVICE(3l,"property_service","物业服务","/propertyManager/propertyService"),
		WASHSERVICE(4l,"property_service","代洗衣服务","/views/kuaidiXiyi/xiyiServerList.jsp"),
		RECEVIECOURIER(5l,"recevie_courier","快递代收","/views/kuaidiXiyi/recevieCourier.jsp");
		
		/** 请求的url */
		private String url;
		/** 类型 */
		private Long type;
		/** 类型名 */
		private String typeName;
		
		private String code;

		private TaskMessageType(Long type,String code, String typeName, String url) {
			this.url = url;
			this.type = type;
			this.code = code;
			this.typeName = typeName;
		}

		public String getUrl() {
			return url;
		}

		public void setUrl(String url) {
			this.url = url;
		}

		public Long getType() {
			return type;
		}

		public void setType(Long type) {
			this.type = type;
		}

		public String getTypeName() {
			return typeName;
		}

		public void setTypeName(String typeName) {
			this.typeName = typeName;
		}

		public String getCode() {
			return code;
		}
		
		public void setCode(String code) {
			this.code = code;
		}
	}

}
